﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using Chinaer.Core.Helper;

namespace Chinaer.Bll
{
    public class ExceptionBLL : Repository, IBll.IException
    {
        Chinaer.IDao.IExceptionDAO addressDAO = new Chinaer.Dao.ExceptionDAO();
        public Model.Common.JsonResult Add(DTO.ExceptionDTO t)
        {
            if (t.CheckIsNull().Success == false)
            {
                return t.CheckIsNull();
            }
            Model.Common.JsonResult jsonResult = new Model.Common.JsonResult();
            Model.Entities.Model_Exception model_Exception = new Model.Entities.Model_Exception();
            Chinaer.Core.Helper.DTOtoEntityObjectHelper.Instance.DTOtoEntityObject(t, model_Exception);
            jsonResult.Success = addressDAO.Add(model_Exception);
            return jsonResult;

        }

        public Model.Common.JsonResult Delete(DTO.ExceptionDTO t)
        {
            throw new NotImplementedException();
        }

        public Model.Common.JsonResult Delete(string id)
        {
            throw new NotImplementedException();
        }

        public Model.Common.JsonResult Update(DTO.ExceptionDTO t)
        {
            throw new NotImplementedException();
        }

        public DTO.ExceptionDTO GetByID(string id)
        {
            throw new NotImplementedException();
        }
    }
}
